﻿
@model RTW.OA.Models.dinner_order
@{

    Layout = "~/Views/Shared/_LayoutBase.cshtml";
}

@section styles{

}
<div id="dMain">
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="ibox" style="margin-bottom: 0px;">
            <div class="ibox-title">
                <h4>@ViewBag.Title </h4>
            </div>
            <div class="ibox-content">
                @using (Html.BeginForm("OrderEdit", "Dinner", FormMethod.Post, new { area = "Common", id = "orderfrom", name = "orderfrom" }))
                {
                    @Html.AntiForgeryToken()
				
                    <div class="from-content">
																																                        <dl>
                            <dt>用户名</dt>
                            <dd>
							    @Html.EditorFor(m => m.USER_NAME, new { htmlAttributes = new { @class = "input normal form-control"  ,datatype="*", nullmsg=" ", errormsg=" ", sucmsg=" "} })
                            </dd>
                        </dl>
																			                        <dl>
                            <dt>部门</dt>
                            <dd>
							    <div class="rule-single-select">@Html.DropDownListFor(m => m.FY_ID, ViewBag.FY_IDData as List<SelectListItem>, new { @Class = "form-control"  })</div>
                            </dd>
                        </dl>
																			                        <dl>
                            <dt>订餐的日期</dt>
                            <dd>
							    @Html.EditorFor(m => m.BOOK_DATE, new { htmlAttributes = new { @Class = "input rule-date-input form-control", onfocus = "WdatePicker({ dateFmt: 'yyyy-MM-dd HH:mm:ss'})"  } })
                            </dd>
                        </dl>
																			                        <dl>
                            <dt>用餐标识</dt>
                            <dd>
							    <div class="rule-single-select">@Html.DropDownListFor(m => m.WHICH_MEAL, ViewBag.WHICH_MEALData as List<SelectListItem>, new { @Class = "form-control"  })</div>
                            </dd>
                        </dl>
																			                        <dl>
                            <dt>菜单</dt>
                            <dd>
							    <div class="rule-single-select">@Html.DropDownListFor(m => m.MENU_ID, ViewBag.MENU_IDData as List<SelectListItem>, new { @Class = "form-control"  })</div>
                            </dd>
                        </dl>
																			                        <dl>
                            <dt>菜单数量</dt>
                            <dd>
							     @Html.EditorFor(m => m.MENU_NUM, new { htmlAttributes = new { Class = "input small form-control"  } })
                            </dd>
                        </dl>
																			                        <dl>
                            <dt>菜单单价</dt>
                            <dd>
							    @Html.EditorFor(m => m.MENU_PRICE, new { htmlAttributes = new { @class = "input normal form-control"  } })
                            </dd>
                        </dl>
																																                        <dl>
                            <dt>下订单时间</dt>
                            <dd>
							    @Html.EditorFor(m => m.ORDER_TIME, new { htmlAttributes = new { @Class = "input rule-date-input form-control", onfocus = "WdatePicker({ dateFmt: 'yyyy-MM-dd HH:mm:ss'})"  } })
                            </dd>
                        </dl>
																				  @Html.HiddenFor(m=>m.ID)
													                     
                    </div>
                    <div class="from-footer">
                        <div class="btn-wrap" style="position: fixed;" onclick="savefrom()">
                            <a class="btn btn-sm btn-primary radius">
                                <i class="iconfont icon-save"></i>
                                提交保存
                            </a>
                            <a class="btn btn-sm btn-warning radius" onclick="parent.closeTab('6202')">
                                <i class="iconfont icon-fanhui"></i>
                                取消关闭
                            </a>
                        </div>
                    </div>
                }
            </div>
        </div>
    </div>
</div>
@section scripts{
    <script src="@Url.Content("~/Content/JS/common/WdatePicker/WdatePicker.js")"></script>
    <script type="text/javascript" charset="utf-8" src="@Url.Content("~/Content/JS/common/jquery/Validform_v5.3.2_min.js")"></script>
    <script type="text/javascript" charset="utf-8" src="@Url.Content("~/Content/JS/common/artdialog/dialog-plus-min.js")"></script>
    <script type="text/javascript" charset="utf-8" src="@Url.Content("~/Content/JS/common/webuploader/webuploader.min.js")"></script>
    <script type="text/javascript" charset="utf-8" src="@Url.Content("~/Content/editor/ueditor.config.js")"></script>
    <script type="text/javascript" charset="utf-8" src="@Url.Content("~/Content/editor/ueditor.all.min.js")"></script>
    <script type="text/javascript" charset="utf-8" src="@Url.Content("~/Content/editor/lang/zh-cn/zh-cn.js")"></script>
    @*<script type="text/javascript" charset="utf-8" src="../js/uploader.js"></script>*@

    <script src="@Url.Content("~/Content/JS/common/from.js")"></script>
    <script>
        $(function () {
            //初始化表单验证
            $("#orderfrom").initValidform();

        });
        function savefrom() {
            $("#orderfrom").submit();
        }

    </script>

}